package com.alexjavi.eneagrama.personal;

import com.actionbar.MiBaseActivity;
import com.witejavi.eneagrama.R;

import android.os.Bundle;
import android.view.MenuItem;
import android.view.View;
import android.widget.LinearLayout;

public class ConsejosDelConsultor extends MiBaseActivity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);

		activarActionBar(true);

		int numero = getIntent().getExtras().getInt("numero");
		LinearLayout l;
		switch (numero) {
		case 1:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo1);
			l.setVisibility(View.VISIBLE);
			break;
		case 2:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo2);
			l.setVisibility(View.VISIBLE);
			break;
		case 3:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo3);
			l.setVisibility(View.VISIBLE);
			break;
		case 4:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo4);
			l.setVisibility(View.VISIBLE);
			break;
		case 5:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo5);
			l.setVisibility(View.VISIBLE);
			break;
		case 6:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo6);
			l.setVisibility(View.VISIBLE);
			break;
		case 7:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo7);
			l.setVisibility(View.VISIBLE);
			break;
		case 8:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo8);
			l.setVisibility(View.VISIBLE);
			break;
		case 9:
			l = (LinearLayout) findViewById(R.id.LinearLayoutConsejo9);
			l.setVisibility(View.VISIBLE);
			break;
		}
	}

	@Override
	protected int getLayoutResource() {
		return R.layout.consejos_consultor;
	}

	@Override
	public boolean onOptionsItemSelected(MenuItem item) {
		switch (item.getItemId()) {
		case android.R.id.home:
			finish();
			return true;
		}

		return super.onOptionsItemSelected(item);
	}

}